Optimal. Leaf size=26 \[ -\frac {a \cos (c+d x)}{d}-\frac {a \log (\cos (c+d x))}{d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 26, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 3, integrand size = 17, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.176, Rules used = {3957, 2786, 45}
\begin {gather*} -\frac {a \cos (c+d x)}{d}-\frac {a \log (\cos (c+d x))}{d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 45
Rule 2786
Rule 3957
Rubi steps
\begin {align*} \int (a+a \sec (c+d x)) \sin (c+d x) \, dx &=-\int (-a-a \cos (c+d x)) \tan (c+d x) \, dx\\ &=\frac {\text {Subst}\left (\int \frac {-a+x}{x} \, dx,x,-a \cos (c+d x)\right )}{d}\\ &=\frac {\text {Subst}\left (\int \left (1-\frac {a}{x}\right ) \, dx,x,-a \cos (c+d x)\right )}{d}\\ &=-\frac {a \cos (c+d x)}{d}-\frac {a \log (\cos (c+d x))}{d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.02, size = 37, normalized size = 1.42 \begin {gather*} -\frac {a \cos (c) \cos (d x)}{d}-\frac {a \log (\cos (c+d x))}{d}+\frac {a \sin (c) \sin (d x)}{d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.04, size = 24, normalized size = 0.92
method | result | size |
derivativedivides | \(\frac {a \left (-\frac {1}{\sec \left (d x +c \right )}+\ln \left (\sec \left (d x +c \right )\right )\right )}{d}\) | \(24\) |
default | \(\frac {a \left (-\frac {1}{\sec \left (d x +c \right )}+\ln \left (\sec \left (d x +c \right )\right )\right )}{d}\) | \(24\) |
risch | \(i a x +\frac {2 i a c}{d}-\frac {a \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )}{d}-\frac {a \cos \left (d x +c \right )}{d}\) | \(45\) |
norman | \(-\frac {2 a}{d \left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}+\frac {a \ln \left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}-\frac {a \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}{d}-\frac {a \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}{d}\) | \(78\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.26, size = 23, normalized size = 0.88 \begin {gather*} -\frac {a \cos \left (d x + c\right ) + a \log \left (\cos \left (d x + c\right )\right )}{d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 2.88, size = 25, normalized size = 0.96 \begin {gather*} -\frac {a \cos \left (d x + c\right ) + a \log \left (-\cos \left (d x + c\right )\right )}{d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} a \left (\int \sin {\left (c + d x \right )} \sec {\left (c + d x \right )}\, dx + \int \sin {\left (c + d x \right )}\, dx\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.42, size = 32, normalized size = 1.23 \begin {gather*} -\frac {a \cos \left (d x + c\right )}{d} - \frac {a \log \left (\frac {{\left | \cos \left (d x + c\right ) \right |}}{{\left | d \right |}}\right )}{d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.04, size = 20, normalized size = 0.77 \begin {gather*} -\frac {a\,\left (\cos \left (c+d\,x\right )+\ln \left (\cos \left (c+d\,x\right )\right )\right )}{d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________